package com.itheima.service;

import com.itheima.entity.PageResult;
import com.itheima.pojo.Role;

import java.util.List;

/**
 * @author Diamond
 * @time 2019/11/13/20:22
 */
public interface RoleService {
    //增加
    void add(Role role, Integer[] permissionIds, Integer[] menuIds);
    //分页查询
    PageResult findPage(Integer currentPage, Integer pageSize, String queryString);
    //根据Id查询
    Role findById(Integer id);
    //根据角色id查询权限id
    List<Integer> findPermissionIdsByRoleId(Integer id);
    //根据角色id查询菜单id
    List<Integer> findMenuIdsByRoleId(Integer id);
    //编辑
    void edit(Role role, Integer[] permissionIds, Integer[] menuIds);
    //删除
    void delete(Integer id);
    //查询全部
    List<Role> findAll();

}
